FIGS. 10A to 10D shows a conventional universal serial bus (USB) system 1000. A system 1000 can include a controller section 1002 and a system memory 1004. A controller section 1002 can include a processor 1006 and a host controller driver (HCD) 1008, which is software executed by the processor.
Referring to FIG. 10A, it is assumed that in a previous operation HCD 1008 has created a data structure 1010 in system memory 1004 that includes a linked-list of USB endpoint descriptors (EP1, EP2). As is well known, endpoint descriptors (EP1, EP2) can describe logical endpoints for data transfers. Though not shown in FIG. 10A, each USB endpoint descriptor (EP1, EP2) can include a pointer to a queue of one or more USB transfer descriptors. The USB transfer descriptors define buffer sections accessed in a data transfer operation. A processor 1006 can traverse the data structure 1010, servicing endpoints according to a predefined order, to thereby control transfers over one or more USB buses. FIG. 10A also shows transfer data 1012 arriving for a new endpoint (EP3). The data structure 1010 remains unchanged as only part of the transfer data has been received.
Referring to FIG. 10B, in response to receiving all of the transfer data 1012, HCD 1008 (by operation of processor 1006) modifies data structure 1010 by inserting a new USB endpoint (EP3), along with USB transfer descriptors (TD0 to TDn) for the new endpoint (EP3). The newly added USB transfer descriptors (TD0 to TDn) can have physical memory addresses to locations of the transfer data.
It is noted that HCD 1008 stores the entire transfer data 1012 in system memory 1002 before scheduling transfer packets (by inserting transfer descriptors into the data structure). Further, modifications to data structure 1010 may require halts to the processing of endpoints.
Referring to FIG. 10C, with changes to the data structure 1010 complete, transfers for the new EP (EP3) can take place. Processor 1006 can initiate a transfer by sending a control packet (OUT TOKEN) for a data channel.
As shown in FIG. 10D, as processor 1006 traverses the data structure 1010 and arrives at endpoint EP3, it can start transferring the data via a data packet.
FIG. 11 is a diagram showing a representation of another conventional USB system 1100. A processor 1106 can manage a data structure in system memory 1104 that includes “vertical pointers” 1110-0 and “horizontal pointers” 1110-1. A processor 1106 manages the data structure 1110-0/1, updating the various pointers as requests for adding endpoints, removing endpoints, and adding new data transfers is received.
Horizontal pointers 1110-1 can be linked-lists of endpoints (EP0 to EP3), where each endpoint points to a queue of transfer descriptors (TD0 to TDn).
Vertical pointers 1110-0 can be the queues of transfer descriptors, each identifying a buffer of data that transmits or receives data for its endpoint. Such vertical pointers 1110-0-0 can include physical addresses identifying locations in a buffer memory 1114 for receiving/storing transfer data.
From the above, it is understood that in conventional systems, for large data transfers, a large amount of system memory can be needed to buffer the data prior to constructing endpoint descriptors for the data. Further, a processor must dedicate significant bandwidth to manage the data structure, as it is traversed and updated. Correspondingly, an HCD can be a relatively complex piece of software, in order to manage the data structure.
When a USB controller is implemented as an integrated circuit, the need for relatively large memories (to accommodate large data transfer sizes, and a complex HCD), can lead to large die size, increasing cost and footprint: both can be undesirable, particularly in portable devices. Further, a larger memory in combination with an active processor, can increase power consumption of the device, another undesirable feature.
Standard USB systems typically include a computer (e.g., desktop or laptop computer) as a host device. In such systems, there can be sufficient computing power and memory to accommodate data transfers among various peripheral (i.e., slave) devices. However, portable standards have arisen, such as USB on-the-go (USB-OTG), which can enable devices that are typically peripherals to operate as hosts. Thus, a smaller device, such as a camera, printer or keyboard, can connect directly to another peripheral device, and act as a host device in the system.
However, implementing conventional host architectures into such smaller devices can often require undesirably large die sizes and power consumption, as noted.